Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rename and improve pluggables #428

Merged
merged 10 commits into from
Nov 9, 2024

Conversation

devkral
Copy link
Contributor

@devkral devkral commented Nov 6, 2024

Checklist

  • The code has 100% test coverage.
  • The documentation was properly created or updated (if applicable) following the correct guidelines and appropriate language.
  • I branched out from the latest main or is a sub-branch.

Summary or description

Changes:

  • unrestrict pluggables logic so also Extension and Extension classes are elligable
  • rename pluggables to extensions
  • allow control about extension execution order

Copy link
Collaborator

@tarsil tarsil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm good with making the pluggable system better which is a great addition here. For the Routing its better in a different PR because its a lot of changes in one go.

For the routing we need:

  1. Tests for the new way of doing this in an application level and at least inside an Include.
  2. Tests with OpenAPI. We want to make sure everything is displaying properly. It doesn't need to be a deep test but a simple new test should be enough to prove this works.

docs/en/docs/pluggables.md Outdated Show resolved Hide resolved
docs_src/pluggables/manual.py Outdated Show resolved Hide resolved
docs_src/pluggables/standalone.py Show resolved Hide resolved
esmerald/applications.py Show resolved Hide resolved
@devkral devkral force-pushed the devkral/feature/improved_pluggables_and_routing branch from a820168 to 8555008 Compare November 7, 2024 19:48
@devkral devkral changed the title improved pluggables and routing improved pluggables Nov 7, 2024
- simplify routing by allowing just passing HTTP/Websocket Handlers to
  routes
@devkral devkral force-pushed the devkral/feature/improved_pluggables_and_routing branch from 8555008 to f03e157 Compare November 8, 2024 02:33
- fix pluggables logic, pluggables contains now extensions and convert
  pluggables on the fly
- unrestrict pluggables, assigning extensions instances and classes is
  now possible too. The extend logic is now executed automatically
- rename pluggables to extensions and deprecate earlier name
- fix bug that extend is called too early
- add helper for extensions to reorder the execution
- add extensions tests
- validate deprecation works
@devkral devkral force-pushed the devkral/feature/improved_pluggables_and_routing branch from f03e157 to bb97e2c Compare November 8, 2024 04:18
@devkral devkral changed the title improved pluggables rename and improve pluggables Nov 8, 2024
@devkral devkral changed the title rename and improve pluggables WIP: rename and improve pluggables Nov 8, 2024
- add reorder test case and fix bugs
- bugfixes docs (missing refs)
- add docs for reordering

Note: the russian link was autoinjected
- check always against the ExtensionProtocol
- update tests and docs
@devkral devkral changed the title WIP: rename and improve pluggables rename and improve pluggables Nov 8, 2024
@devkral
Copy link
Contributor Author

devkral commented Nov 8, 2024

it is not the pluggable system anymore but the extension system ;) . The old names are deprecated but tested.

docs/en/docs/extensions.md Outdated Show resolved Hide resolved
docs/en/docs/references/extensions.md Outdated Show resolved Hide resolved
docs/en/docs/release-notes.md Outdated Show resolved Hide resolved
@tarsil tarsil merged commit 22b7b48 into main Nov 9, 2024
5 checks passed
@tarsil tarsil deleted the devkral/feature/improved_pluggables_and_routing branch November 9, 2024 09:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants